function CloseCurrentWindow() {
	/* because javascript can only close a window it has a reference to
	 * we must first open the current url (i.e. window.location) in a new window
	 * (e.g. window.open()) but we specify the 'name' of the window to be '_self'.
	 * Specifying the name as '_self' causes the current document to be replaced
	 * with the document specified by the url. Only then can we call close on the
	 * window.
	 * NOTE: for some reason this does not work on FF 3. But is working with IE 6,
	 * Chrome 5 and Safari 5
	 */
	ww = window.open(window.location, "_self");
	ww.close();
}